package com.dkm.service;

import java.util.List;
import java.util.Optional;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import com.dkm.entity.Department;
import com.dkm.util.ResultUtil;

public interface DepartmentService {

	/**
	 * 多条件分页查询部门信息
	 * @param department
	 * @param pageable
	 * @return
	 */
	Page<Department> findAllDepartments(Department department,Pageable pageable);
	
	/**
	 * 新增和保存部门
	 * @param department
	 * @return
	 */
	ResultUtil saveAndFlushDepartment(Department department);
	/**
	 * 删除部门信息
	 * @param department_id
	 * @return
	 */
	ResultUtil deleteDepartment(String department_id);
	
	/**
	 * 获取全部部门信息
	 * @return
	 */
	List<Department> getAllDepartments();
	/**
	 * 根据部门id获取部门信息
	 * @param department_id
	 * @return
	 */
	Optional<Department> findById(String department_id);
}
